-
-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
NativeAoT support #107
base: master
Are you sure you want to change the base?
NativeAoT support #107
Conversation
…e now properly annotated
I forgot i had to do it, but to make the Godot sample work with PublishAoT another necessary change is to the json serialization used to communicate with the lobby server, have it use JsonTypeInfos (or JsonSerializerContext source generation) instead of reflection. |
Hi, thanks for the contribution, I will get some time to review these changes |
My pleasure! |
I don’t mind; you are welcome to open issues and/or discussions. Regarding this pull request:
|
Sure, I won't have time to work on it this week but I think I'll manage for the next one. |
Closes #56
Removing code when "AOT_ENABLED" is set is no longer necessary with .net9.0, thanks to Intrinsic APIs marked RequiresDynamicCode now including MethodInfo.MakeGenericMethod.
I annotated the entire library (and tests) with the required attributes and provided overloads that don't require dynamically accessed code to the few methods that still require it (mostly due to json serialization).
Also made Backdash.Analyzers compatible with visual studio on the way, for convenience.
Tests succeed both with and without PublishAoT, the Godot sample also exports and plays with PublishAoT with a single minimal change: the export setting "Embed Build Outputs" makes it crash on startup.